package com.elvis.lifecardemo;

import android.app.Application;

import com.avos.avoscloud.AVOSCloud;
import com.avos.avoscloud.AVObject;
import com.elvis.lifecardemo.bean.Comments;
import com.elvis.lifecardemo.bean.Like;
import com.elvis.lifecardemo.bean.Post;

/**
 * Created by G on 2018/9/29.
 */

public class MyApplication extends Application {

    @Override
    public void onCreate() {
        super.onCreate();

        //调试日志 放在 SDK 初始化语句 AVOSCloud.initialize() 后面，只需要调用一次即可
        AVOSCloud.setDebugLogEnabled(true);

        //应用初始化的地方，在调用 AVOSCloud.initialize() 之前注册子类
        AVObject.registerSubclass(Post.class);
        AVObject.registerSubclass(Comments.class);
        AVObject.registerSubclass(Like.class);
        // 初始化参数依次为 this, AppId, AppKey
        AVOSCloud.initialize(this,"gPP3PmOVTh2GD07KOqPj1XUV-gzGzoHsz","1NNBEQW4QO2vEdsfgfedeyjx");
    }
}
